// 命令相关接口
import request from '@/lib/request';

export const list = (params) => request({
  url: '/api/command/', method: 'get', params
})

export const get = (params, id) => request({
  url: `/api/command/${id}`, method: 'get', params
})

export const create = (data) => request({
  url: '/api/command/', method: 'post', data
})

export const runBatch = (data) => request({
  url: '/api/run_batch_command/', method: 'post', data
})

export const rm = (params, id) => request({
  url: `/api/command/${id}`, method: 'delete', params
})
